import { http } from '@/utils/http/axios'
import { BasicResultModel } from '../model/basicModel'

/**
 * X号码表
 * @date 2025-08-20
 * @author exchenming
 * @Email 276490943@qq.com
 */
enum Api {
  list = '/x/noQs/list',
  get = '/x/noQs/get',
  save = '/x/noQs/save',
  remove = '/x/noQs/remove',
  lock = '/x/noQs/lock',
  cancel = '/x/noQs/cancel',
  uploadNoQsExcel='/x/noQs/import',
  getAllProvince='/x/noQs/getAllProvince',
  getCityByProvince='/x/noQs/getCityByProvince',
  batchUse='/x/noQs/batchUse',
  batchLock='/x/noQs/batchLock',
  batchCancel='/x/noQs/batchCancel',
}

export const listNoQs = (params: any) => http.post<BasicResultModel>({ url: Api.list, params })
export const getNoQs = (params: any) => http.post<BasicResultModel>({ url: Api.get, params })
export const saveNoQs = (data: any) => http.post<BasicResultModel>({ url: Api.save, data })
export const removeNoQs = (params: any) => http.delete<BasicResultModel>({ url: Api.remove, params })
export const lockNoQs = (params: any) => http.post<BasicResultModel>({ url: Api.lock, params })
export const cancelNoQs = (params: any) => http.post<BasicResultModel>({ url: Api.cancel, params })
// export const uploadNoQsExcel = (data: any) => http.post<BasicResultModel>({ url: Api.uploadNoQsExcel, data })
export const uploadNoQsExcel = (data: any) => http.uploadFile({ url: Api.uploadNoQsExcel},data)
export const getAllProvince = (params: any) => http.get({ url: Api.getAllProvince,params})
export const getCityByProvince = (params: any) => http.get({ url: Api.getCityByProvince,params})
export const batchUseNoQs = (data: any) => http.post({ url: Api.batchUse,data})
export const batchLockNoQs = (data: any) => http.post({ url: Api.batchLock,data})
export const batchCancelNoQs = (data: any) => http.post({ url: Api.batchCancel,data})
 